feat(new): add --no-hooks flag to skip post-create hooks#91
feat(new): add --no-hooks flag to skip post-create hooks#91helizaga merged 7 commits intocoderabbitai:mainfrom
Conversation
Add --no-verify flag completion for Bash, Zsh, and Fish shells to support skipping post-create hooks when creating new worktrees.
- Add --no-verify flag to README.md Options section - Add --no-verify to automation flags table in docs/advanced-usage.md - Add --no-verify test case to CLAUDE.md manual testing workflow - Complete Phase 3 of --no-verify implementation plan
- Executed all 7 test cases from Phase 4 of the plan - All tests passed successfully - Verified default behavior, flag functionality, flag combinations - Confirmed shell completions and help text updates - Validated scope isolation (only affects postCreate hooks) - Test environment cleaned up after execution All tests PASS - feature is production-ready
The --no-verify flag implementation has been completed and fully tested. All plan items were successfully implemented across code, completions, and documentation. Test report confirms all 7 test cases passed.
|
Caution Review failedThe pull request is closed. WalkthroughAdds a new CLI flag Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
lgtm! thanks |
Description
Add a
--no-verifyflag togit gtr newcommand that skips execution of post-create hooks.I chose
--no-verifyover--no-hooksfor consistency with git's convention (git commit --no-verify,git push --no-verify). However, I'm open to changing this to--no-hooksif preferred.Motivation
Fixes #90
Type of Change
Testing
Manual Testing Checklist
Tested on:
Core functionality tested:
Test report: https://github.com/lucasrcezimbra/git-worktree-runner/blob/be59e39ffdac88549b66014d7a59a3ebbbb1de59/test-report.md
git gtr new <branch>- Create worktreegit gtr go <branch>- Navigate to worktreegit gtr editor <branch>- Open in editor (if applicable)git gtr ai <branch>- Start AI tool (if applicable)git gtr rm <branch>- Remove worktreegit gtr list- List worktreesgit gtr config- Configuration commands (if applicable)git gtr new --no-verifyTest Steps
git config --add gtr.hook.postCreate "echo 'Created!' > /tmp/gtr-test"./bin/gtr new test-with-hooks cat /tmp/gtr-test # Should show "Created!" rm /tmp/gtr-test--no-verify:./bin/gtr new test-no-verify --no-verify ls /tmp/gtr-test # Should fail - file should NOT existExpected behavior: When
--no-verifyis passed, post-create hooks should be skipped.Actual behavior: Works as expected. Hooks run normally without the flag, and are skipped with
--no-verify.Breaking Changes
Checklist
Before submitting this PR, please check:
git gtr(production) and./bin/gtr(development)License Acknowledgment
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache License 2.0.
Summary by CodeRabbit
New Features
Documentation
Tests